<template>
	<view class="setting-child">
		<NavBar :title="pageType" :left="true" />
		<!-- 个人信息 -->
		<UserInfo v-if="pageType == '个人信息'"/>
		<!-- 账号安全 -->
		<AccountSecurity v-if="pageType == '账号安全'" />
		<!-- 建议反馈 -->
		<Feedback v-if="pageType == '建议反馈'"/>
		<!-- 关于信购 -->
		<About v-if="pageType == '关于信购'"/>
		<!-- 公司招聘 -->
		<Invit v-if="pageType == '公司招聘'"/>
		<!-- 切换账号 -->
		<SwitchAccount v-if="pageType == '切换账号'"/>
		
	</view>
</template>

<script setup>
	import { ref } from 'vue';
	import { onLoad } from '@dcloudio/uni-app'
	import NavBar from '@/components/NavBar.vue';
	// components 
	import UserInfo from './components/UserInfo.vue';
	import AccountSecurity from './components/AccountSecurity.vue';
	import Feedback from './components/Feedback.vue';
	import About from './components/About.vue';
	import Invit from './components/Invit.vue';
	import SwitchAccount from './components/SwitchAccount.vue';
	const pageType = ref('')
	
	
	const submit = () => {
		console.log('确认提交');
	}
	onLoad((e) => {
		const { title } = e
		pageType.value = title
	})
</script>

<style lang="scss" scoped>
</style>
